import java.util.Scanner;

/**
 * Created by JiaJia on 2019/4/11 0011.
 */
public class WeiZhong03 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while (sc.hasNext()) {
            int n = sc.nextInt();
            int k = sc.nextInt();
            int m = sc.nextInt();
            System.out.println(countTime(n, k, m));
        }
        sc.close();
    }

    private static int countTime(int a, int b, int c) {
        int temp = (a % b) + (a / b);
        int result = temp * c;
        return result;
    }
}